import request from '@/utils/request'
export function fetchList(params) {
  return request({
    url:'/product/goods/list/'+params.pageNum+'/'+params.pageSize,
    method:'post',
    data:params.object
  })
}

export function getAllProducts() {
  return request({
    url:'/product/all',
    method:'post'
  })
}
export function getGoodsByProduct(params) {
  return request({
    url:'/product/goods/getGoodsByProduct',
    method:'post',
    params:params
  })
}

export function querySpecByProductCode(params) {
  return request({
    url:'/product/querySpecByProductCode',
    method:'post',
    params:params
  })
}

export function addSpecRang(params) {
  return request({
    url:'/product/spec/range/add',
    method:'post',
    data:params
  })
}

export function querySpecRangByspecCode(params) {
  return request({
    url:'/product/spec/range/add',
    method:'post',
    data:params
  })
}

export function fetchListSpecRang(params) {
  return request({
    url:'/product/spec/range/list',
    method:'post',
    data:params
  })
}

export function addSpecRangValue(params) {
  return request({
    url:'/product/spec/range/add',
    method:'post',
    data:params
  })
}

export function addGoodsService(params) {
  return request({
    url:'/product/goods/add',
    method:'post',
    data:params
  })
}

export function updateSpecRangValueAvailable(params) {
  return request({
    url:'/product/spec/range/available',
    method:'post',
    data:params
  })
}

export function updateSpecRangValueDisable(params) {
  return request({
    url:'/product/spec/range/disable',
    method:'post',
    data:params
  })
}

export function updateSpecAvailable(params) {
  return request({
    url:'/product/spec/available',
    method:'post',
    data:params
  })
}


export function updateSpecDisable(params) {
  return request({
    url:'/product/spec/disable',
    method:'post',
    data:params
  })
}

export function updateDeleteStatus(params) {
  return request({
    url:'/product/update/deleteStatus',
    method:'post',
    params:params
  })
}




